package com.atm.thirdplt.common.utils.xml;

import com.atm.thirdplt.common.utils.StringUtils;
import com.thoughtworks.xstream.converters.basic.DateConverter;

import java.util.TimeZone;

/**
 * @ClassName CustomDateConverter
 * @Description TODO
 * @Author wenyf
 * @Version 1.0
 **/
public class CustomDateConverter extends DateConverter {
    public CustomDateConverter() {
    }

    ;

    /**
     * 构造方法
     *
     * @param string
     * @param strings
     * @param timeZone
     */
    public CustomDateConverter(String string, String[] strings, TimeZone timeZone) {
        super(string, strings, timeZone);
    }

    /**
     * 时间日期转换
     */
    @Override
    public Object fromString(String str) {
        if (StringUtils.isBlank(str)) {
            return null;
        }
        return super.fromString(str);
    }

}
